/*
 * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
 * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Enum.java to edit this template
 */
package com.yxw.live_vod_boot.enums;

/**
 *
 * @author Administrator
 */
public enum DelayJobTypeEnum {
    //延时任务类型:0推流状态,1直播结束,2直播罚款后金额不足停播,3店铺禁播,4直播结束,5直播异常
    DELAY_PUSH_STATE(0, "推流状态"),
    DELAY_LIVE_END(1, "直播结束"),
    DELAY_STOP_LIVE(2, "直播罚款后金额不足延时停播"),
    LIVE_RESUME_STOP(3, "延时解除中断"),
    LIVE_RESUME_LIMITED(4, "延时解除禁播");
    


    DelayJobTypeEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public String getDesByCode(Integer code) {
        for (DelayJobTypeEnum statusEnum : DelayJobTypeEnum.values()) {
            if (statusEnum.getCode().equals(code)) {
                return statusEnum.getDesc();
            }
        }
        return code.toString();
    }

    
    private Integer code;
    private String desc;


    public Integer getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }    
}
